# coding=utf-8
from res.fun import _create_font
from res.glo import color
from lib.ZClass import ZClass

class ZLabel(ZClass):
    def __init__(self , surface ):
        super(ZLabel , self).__init__()
        self.screen = surface
        self.text = u'文字'
        self.color = color['label']['default']
        self.image = _create_font(self.text , self.color)
        self.rect = self.image.get_rect()

    def draw(self):
        if self.isRunning :
            self.image = _create_font(self.text ,self.color)
            self.screen.blit(self.image , self.rect.topleft)

    def update(self):
        pass
